package com.socialuni.sdk.utils;

import com.socialuni.sdk.api.model.RO.user.base.SocialUserRO;
import com.socialuni.sdk.model.DO.user.UserDO;

public class CommonUserROUtil {
    public static SocialUserRO getMineUser(UserDO userDO) {
        return CommonUserROUtil.userDOToRO(userDO, true);
    }

    public static SocialUserRO userDOToRO(UserDO userDTO, Boolean isMine) {
        //user基础信息
        SocialUserRO user = new SocialUserRO();
        //user详情信息
        user.setId(userDTO.getId().toString());
        user.setNickname(userDTO.getNickname());
        user.setAvatar(userDTO.getAvatar());
        user.setGender(userDTO.getGender());
        user.setAge(userDTO.getAge());
        user.setCity(userDTO.getCity());
        return user;
    }
}